# coding:utf-8
"""
    Create time : 2020/11/4 - 9:55
    Author : Jimy
    Email : 1650015040@qq.com
"""
class StudentController(object):
    def __init__(self,model,view):
        self.__model = model
        self.__view = view
    def set_student_name(self,name):
        self.__model.set_name(name)
    def get_student_name(self):
        return self.__model.get_name()
    def set_student_age(self,age):
        self.__model.set_age(age)
    def get_student_age(self):
        return self.__model.get_age()
    # 更新视图
    def update_view(self):
        # 更新
        # self.__view.show_detail(self.__model.get_name(),)
        self.__view.show_detail(self.get_student_name(),self.get_student_age())
